package org.terracotta.toolkit.samples;

public class Range {

    long lowerLimit;

    long upperLimit;

    public Range(long lowerLimit, long upperLimit) {
        this.lowerLimit = lowerLimit;
        this.upperLimit = upperLimit;
    }

    public long getLowerLimit() {
        return lowerLimit;
    }

    public void setLowerLimit(long lowerLimit) {
        this.lowerLimit = lowerLimit;
    }

    public long getUpperLimit() {
        return upperLimit;
    }

    public void setUpperLimit(long upperLimit) {
        this.upperLimit = upperLimit;
    }

    public long getRandomKey() {
        return (long) (Math.random() * (upperLimit - lowerLimit + 1) );
    }
}